
let height = document.documentElement.clientHeight;
$("main").style.height = (height - 100) + "px";

var editor = mdeditor({
    id: 'mark',
    source: "source", 
});

editor.setMarkdown(document.getElementById('source').innerHTML);